<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<ul>
			<li><img src="../1.jpg" /></li>
			<li style="display: none;"><img src="../img/btn_login_n.png" /></li>
		</ul>
		<button type="button" onclick="next()">下一张</button>
		<script type="text/javascript">
			function next() {
				let ul = document.getElementsByTagName("ul")[0];
				let i = 1;

				for (let index in ul.children) {
					let item = ul.children[index];
					console.log(item);
					if (i === parseInt(index)) {
						item.style.display = "inline-block";
					}else{
						item.style.display = "none";
					}
				}
				i++;
			}
		</script>
	</body>
</html>
